<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      let arr = ['a', 'b', 'c', 'd']
      //原始取出的数组的值，并赋值给变量
      let a1 = arr[0]
      let a2 = arr[0]
      let a3 = arr[0]
      let a4 = arr[0]
      //这种就称之为结构赋值，一次性赋值给4个变量
      let [a, b, c, d] = arr
      console.log(a, b, c, d)
    </script>
  </body>
</html>
